import pandas as pd

ser_obj = pd.Series([10, 20, 30, 40, 50], index=['one', 'two', 'three', 'four', 'five'])

# 通过位置索引获取 ser_obj 单个数据
result = ser_obj[2]
# print(result)
# print(ser_obj['three'] )
# print(ser_obj[[0, 2, 3]])
# print(ser_obj[['one', 'three', 'four']])
# print(ser_obj[1:3] )
print(ser_obj['two':'four'])